import requests
class config:
    def __init__(self):
        self.url='http://10.59.9.18'
        self.session=requests.session()

    def request(self,method,path,**kwargs):
        url=f'{self.url}{path}'
        requests=self.session.request(method,url,**kwargs)
        return requests
    # 获取
    def get(self,path,**kwargs):
        return self.request('GET',path,**kwargs)
    # 删除
    def delete(self,path,**kwargs):
        return self.request('DELETE',path,**kwargs)
    # 修改
    def update(self,path,**kwargs):
        return self.request('UPDATE',path,**kwargs)
    # 添加
    def post(self,path,**kwargs):
        return self.request('POST',path,**kwargs)